﻿using Abp.Web.Mvc.Authorization;
using FutureApp.Authorization;
using FutureApp.Shop;
using System;
using System.Threading.Tasks;
using System.Web.Mvc;

namespace FutureApp.Web.Controllers
{
    [AbpMvcAuthorize(PermissionNames.Pages_Goods)]
    public class GoodsPropertiesController : FutureAppControllerBase
    {
        public IGoodsPropertyAppService GoodsPropertyAppService { get; set; }

        public async Task<ActionResult> List()
        {
            var output = await this.GoodsPropertyAppService.GetGoodsPropertyList();
            return this.View(output);
        }

        public ActionResult Add()
        {
            return this.View();
        }

        public async Task<ActionResult> Edit(Guid id)
        {
            var output = await this.GoodsPropertyAppService.GetGoodsProperty(id);
            return this.View(output);
        }
    }
}